/* CliCli-inspired CMDB Dashboard Theme */
/* Based on https://clicli.com.cn/ - 二次元ACG风格 */
:root {
  /* CliCli cute anime color palette */
  --color-bg-primary: #f5f7fa;
  --color-bg-secondary: #ffffff;
  --color-bg-tertiary: #fef5f8;
  --color-accent-pink: #ff6b9d;
  --color-accent-purple: #c471ed;
  --color-accent-blue: #12cad6;
  --color-accent-orange: #ffa94d;
  --color-accent-success: #51cf66;
  --color-text-primary: #2e3440;
  --color-text-secondary: #6c7589;
  --color-border: #e9ecef;
  --color-hover: #f8f9fa;
  --shadow-soft: 0 2px 12px rgba(255, 107, 157, 0.15);
  --shadow-card: 0 4px 20px rgba(196, 113, 237, 0.1);
  --shadow-hover: 0 8px 30px rgba(196, 113, 237, 0.2);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', Arial, sans-serif;
  background: linear-gradient(135deg, #f5f7fa 0%, #fef5f8 50%, #f5f7fa 100%);
  background-attachment: fixed;
  color: var(--color-text-primary);
  line-height: 1.6;
  position: relative;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: 
    radial-gradient(circle at 20% 50%, rgba(255, 107, 157, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(196, 113, 237, 0.08) 0%, transparent 50%),
    radial-gradient(circle at 40% 80%, rgba(18, 202, 214, 0.05) 0%, transparent 50%);
  pointer-events: none;
  z-index: 0;
}

body::after {
  content: '✨';
  position: fixed;
  font-size: 20px;
  animation: float-emoji 8s ease-in-out infinite;
  opacity: 0.3;
  pointer-events: none;
  z-index: 0;
}

@keyframes float-emoji {
  0%, 100% {
    top: 10%;
    left: 10%;
    transform: translateY(0) rotate(0deg);
  }
  25% {
    top: 15%;
    left: 85%;
    transform: translateY(-20px) rotate(90deg);
  }
  50% {
    top: 75%;
    left: 80%;
    transform: translateY(0) rotate(180deg);
  }
  75% {
    top: 80%;
    left: 15%;
    transform: translateY(-20px) rotate(270deg);
  }
}

#app {
  min-height: 100vh;
  position: relative;
  z-index: 1;
}

/* Scrollbar styling - Cute anime style */
::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: var(--color-bg-primary);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, var(--color-accent-pink), var(--color-accent-purple));
  border-radius: 10px;
  border: 2px solid var(--color-bg-primary);
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(180deg, var(--color-accent-purple), var(--color-accent-pink));
}

/* Button styles - Cute anime inspired */
.btn {
  padding: 10px 24px;
  border: none;
  background: linear-gradient(135deg, var(--color-accent-pink), var(--color-accent-purple));
  color: white;
  cursor: pointer;
  font-weight: 600;
  border-radius: 25px;
  transition: all 0.3s ease;
  font-size: 14px;
  position: relative;
  overflow: hidden;
  box-shadow: var(--shadow-soft);
}

.btn::before {
  content: '✨';
  position: absolute;
  top: 50%;
  left: -20px;
  transform: translateY(-50%);
  opacity: 0;
  transition: all 0.3s ease;
}

.btn:hover::before {
  left: 10px;
  opacity: 1;
}

.btn:hover {
  background: linear-gradient(135deg, var(--color-accent-purple), var(--color-accent-pink));
  box-shadow: var(--shadow-hover);
  transform: translateY(-3px) scale(1.02);
}

.btn:active {
  transform: translateY(-1px) scale(0.98);
}

.btn-danger, .btn-warning {
  background: linear-gradient(135deg, var(--color-accent-orange), #ff8787);
}

.btn-danger:hover, .btn-warning:hover {
  background: linear-gradient(135deg, #ff8787, var(--color-accent-orange));
}

.btn-success, .btn-info {
  background: linear-gradient(135deg, var(--color-accent-blue), #4dabf7);
}

.btn-success:hover, .btn-info:hover {
  background: linear-gradient(135deg, #4dabf7, var(--color-accent-blue));
}

/* Input styles - Cute anime */
input, select, textarea {
  background: var(--color-bg-secondary);
  border: 2px solid var(--color-border);
  color: var(--color-text-primary);
  padding: 12px 16px;
  border-radius: 12px;
  width: 100%;
  font-size: 14px;
  transition: all 0.3s ease;
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--color-accent-pink);
  box-shadow: 0 0 0 3px rgba(255, 107, 157, 0.1);
  background: var(--color-bg-tertiary);
}

/* Card styles - Cute anime inspired */
.card {
  background: var(--color-bg-secondary);
  border: none;
  border-radius: 20px;
  padding: 24px;
  margin-bottom: 20px;
  position: relative;
  box-shadow: var(--shadow-card);
  transition: all 0.3s ease;
  overflow: hidden;
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--color-accent-pink), var(--color-accent-purple), var(--color-accent-blue));
}

.card::after {
  content: '💖';
  position: absolute;
  top: 20px;
  right: 20px;
  font-size: 24px;
  opacity: 0.1;
  transform: rotate(-15deg);
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
}

.card-header {
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--color-border);
  color: var(--color-accent-pink);
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-header::before {
  content: '🌸';
  font-size: 20px;
}

/* Table styles - Cute anime */
table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  background: var(--color-bg-secondary);
  border-radius: 15px;
  overflow: hidden;
}

th, td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--color-border);
}

th {
  background: linear-gradient(135deg, var(--color-bg-tertiary), #fff0f6);
  color: var(--color-accent-pink);
  font-weight: 700;
  font-size: 14px;
}

tr:hover {
  background: var(--color-hover);
}

tr:last-child td {
  border-bottom: none;
}

/* Status badges - Cute anime inspired */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  position: relative;
  box-shadow: var(--shadow-soft);
}

.badge::before {
  content: '';
  width: 8px;
  height: 8px;
  border-radius: 50%;
  animation: pulse-dot 2s ease-in-out infinite;
}

.badge-online {
  background: linear-gradient(135deg, rgba(81, 207, 102, 0.2), rgba(81, 207, 102, 0.1));
  color: var(--color-accent-success);
  border: 2px solid var(--color-accent-success);
}

.badge-online::before {
  background: var(--color-accent-success);
}

.badge-offline {
  background: linear-gradient(135deg, rgba(255, 138, 135, 0.2), rgba(255, 138, 135, 0.1));
  color: #ff6b6b;
  border: 2px solid #ff6b6b;
}

.badge-offline::before {
  background: #ff6b6b;
  animation: none;
}

.badge-unknown {
  background: linear-gradient(135deg, rgba(108, 117, 137, 0.2), rgba(108, 117, 137, 0.1));
  color: var(--color-text-secondary);
  border: 2px solid var(--color-text-secondary);
}

.badge-unknown::before {
  background: var(--color-text-secondary);
  animation: none;
}

.badge-warning {
  background: linear-gradient(135deg, rgba(255, 169, 77, 0.2), rgba(255, 169, 77, 0.1));
  color: var(--color-accent-orange);
  border: 2px solid var(--color-accent-orange);
}

.badge-warning::before {
  background: var(--color-accent-orange);
}

@keyframes pulse-dot {
  0%, 100% {
    transform: scale(1);
    opacity: 1;
  }
  50% {
    transform: scale(1.3);
    opacity: 0.7;
  }
}

/* Loading spinner - Cute anime */
.loading {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid var(--color-border);
  border-radius: 50%;
  border-top-color: var(--color-accent-pink);
  border-right-color: var(--color-accent-purple);
  animation: spin 0.8s ease-in-out infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Form group - Cute anime */
.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 10px;
  color: var(--color-accent-pink);
  font-weight: 600;
  font-size: 14px;
}

/* Utility classes */
.text-center { text-align: center; }
.text-right { text-align: right; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mb-1 { margin-bottom: 10px; }
.mb-2 { margin-bottom: 20px; }
.p-1 { padding: 10px; }
.p-2 { padding: 20px; }

.flex { display: flex; }
.flex-between { display: flex; justify-content: space-between; align-items: center; }
.flex-center { display: flex; justify-content: center; align-items: center; }
.gap-1 { gap: 10px; }
.gap-2 { gap: 20px; }
